package com.decorate.pojo;

import java.io.Serializable;
import lombok.Data;

/**
 * 设计师-设计作品-中间表
 * @TableName architect_production
 */
@Data
public class ArchitectProduction implements Serializable {
    /**
     * 主键
     */
    private Integer id;

    /**
     * 设计师id
     */
    private String architectId;

    /**
     * 设计作品id
     */
    private String productionId;

    /**
     * 是否禁用
     */
    private String isDelete;

    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        ArchitectProduction other = (ArchitectProduction) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getArchitectId() == null ? other.getArchitectId() == null : this.getArchitectId().equals(other.getArchitectId()))
            && (this.getProductionId() == null ? other.getProductionId() == null : this.getProductionId().equals(other.getProductionId()))
            && (this.getIsDelete() == null ? other.getIsDelete() == null : this.getIsDelete().equals(other.getIsDelete()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getArchitectId() == null) ? 0 : getArchitectId().hashCode());
        result = prime * result + ((getProductionId() == null) ? 0 : getProductionId().hashCode());
        result = prime * result + ((getIsDelete() == null) ? 0 : getIsDelete().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", architectId=").append(architectId);
        sb.append(", productionId=").append(productionId);
        sb.append(", isDelete=").append(isDelete);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}